﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Threading.Tasks;
using Teriri.File.Client.Model;
using TouchSocket.Dmtp.Rpc;

namespace Teriri.File.Client.Function
{
    public class LogFunction
    {
        public static PagedList<DecompressingFileLogModel> DecompressingLog(string remoteIPHost, string verifyToken, int page, int  limit)
        {
            var client = RpcClientHelper.GetClient(remoteIPHost, verifyToken);
            var res = client.GetDmtpRpcActor().InvokeResult<PagedList<DecompressingFileLogModel>>("Log_DecompressingLog", page, limit);
            if (res.Succ == false)
                throw new Exception(res.Message);

            return res.Result;
        }
    }
}
